<template>
	<view class="body">
		<view class="li" v-for="(item,index) in recordList" :key="index" @click="handleInfo(item)">
			<view class="head">
				<image :src="'http://shundaiwang.maiss.cn' + item.avatar"></image>
			</view>
			<view class="name">{{item.nickname}}</view>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				queryForm: {
					
				},
				recordList: [],
			}
		},
		onShow() {
			this.getList()
		},
		methods: {
			//获取列表
			getList() {
				this.$Api.getFollowList(this.queryForm).then(res => {
					// console.log('获取列表', res)
					this.recordList = res.result
				}, err => {
					console.log(err)
				})
			},
			//查看详情
			handleInfo(item) {
				uni.navigateTo({
					url: "/pages/user/otherIndex"
				})
			},
		}
	}
</script>

<style lang="scss" scoped>
	.body {
		width: 94%;
		margin: 0 auto;

		.li {
			width: 100%;
			display: flex;
			align-items: center;
			justify-content: flex-start;
			border-bottom: 2upx solid #e5e5e5;
			padding: 20upx 0;

			.head {
				width: 100upx;
				height: 100upx;
				border-radius: 50%;
				overflow: hidden;

				image {
					width: 100%;
					height: 100%;
					display: block;
					margin: 0 auto;
				}
			}

			.name {
				font-size: 28upx;
				margin-left: 30upx;
			}
		}
	}
</style>